import 'package:live_music/http/http_utils.dart';

class UserService {
  static Future login(data) async {
    return await HttpUtils.postRequest(url: '/login/emailLogin', data: data);
  }

  static Future register(data) async {
    return await HttpUtils.postRequest(url: '/login/register', data: data);
  }

  static Future getMailCode(data) async {
    return await HttpUtils.postRequest(url: '/login/getMailCode', data: data);
  }

  static Future getPassword(data) async {
    return await HttpUtils.postRequest(url: '/login/getPassword', data: data);
  }

  static Future checkLoginToken() async {
    return await HttpUtils.postRequest(url: '/login/checkLoginToken');
  }

  static Future getUserInfo() async {
    return await HttpUtils.postRequest(url: '/user/getUserInfo');
  }

  static Future getCountInfo(data) async {
    return await HttpUtils.postRequest(url: '/follow/countFriend', data: data);
  }

  static Future updateUserInfo(data) async {
    return await HttpUtils.postRequest(url: '/user/updateUserInfo', data: data);
  }

  static Future getUserSetting(data) async {
    return await HttpUtils.postRequest(
        url: '/user/queryUserSetting', data: data);
  }

  static Future updateUserSetting(data) async {
    return await HttpUtils.postRequest(
        url: '/user/updateUserSetting', data: data);
  }

  static Future queryUserOwnerMoment(data) async {
    return await HttpUtils.postRequest(
        url: '/user/queryUserOwnerMoment', data: data);
  }

  static Future queryOtherUserMoment(data) async {
    return await HttpUtils.postRequest(
        url: '/user/queryOtherUserMoment', data: data);
  }

  static Future queryCollectVideo(data) async {
    return await HttpUtils.postRequest(
        url: '/collect/queryCollectVideo', data: data);
  }

  static Future queryUserLikeMoment(data) async {
    return await HttpUtils.postRequest(
        url: '/user/queryUserLikeMoment', data: data);
  }

  static Future getOtherUserInfo(data) async {
    return await HttpUtils.postRequest(url: '/user/getUserInfo', data: data);
  }

  static Future queryFriend(data) async {
    return await HttpUtils.postRequest(url: '/follow/queryFriend', data: data);
  }

  static Future follow(data) async {
    return await HttpUtils.postRequest(url: '/follow/follow', data: data);
  }

  static Future cancelFollow(data) async {
    return await HttpUtils.postRequest(url: '/follow/cancelFollow', data: data);
  }

  static Future queryUserFriend(data) async {
    return await HttpUtils.postRequest(
        url: '/follow/queryUserFriend', data: data);
  }

  static Future queryUsers(data) async {
    return await HttpUtils.postRequest(url: '/user/queryUsers', data: data);
  }
}
